package com.cell.dao.user;

import com.cell.pojo.entity.user.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author cloudJiang
 * @since 2022-06-04
 */
@Mapper
public interface UserDao extends BaseMapper<User> {
    List<User> selectCommunityAgentByAdmin(@Param("countryID") int countryID, @Param("provinceID") int provinceID, @Param("cityName") String cityName,
                                           @Param("district") String district, @Param("community") String community);

    List<User> selectCommunityAgent(@Param("countryID") int countryID, @Param("provinceID") int provinceID, @Param("cityName") String cityName,
                                    @Param("district") String district, @Param("community") String community);

    List<User> selectNearbyCommunityAgentByAdmin(@Param("countryID") int countryID, @Param("provinceID") int provinceID, @Param("cityName") String cityName,
                                                 @Param("district") String district);

    List<User> selectNearbyCommunityAgent(@Param("countryID") int countryID, @Param("provinceID") int provinceID, @Param("cityName") String cityName,
                                          @Param("district") String district);

    List<User> selectNearbyDistrictAgentByAdmin(@Param("countryID") int countryID, @Param("provinceID") int provinceID, @Param("cityName") String cityName,
                                                @Param("district") String district);

    List<User> selectNearbyDistrictAgent(@Param("countryID") int countryID, @Param("provinceID") int provinceID, @Param("cityName") String cityName,
                                         @Param("district") String district);

    void deleteUserByAdmin(@Param("userID") Long userID);

    void deleteUser(@Param("userID") Long userID);

    void deleteOrderByAdmin(@Param("orderID") Long orderID);

    void deleteOrder(@Param("orderID") Long orderID);


    void getAll();
}
